package com.ft.admix.bd.adapter;

import android.content.Context;

import com.kwad.sdk.api.KsAdSDK;
import com.kwad.sdk.api.KsInitCallback;
import com.kwad.sdk.api.SdkConfig;
import com.ft.admix.base.ADMixAdapterIniter;
import com.ft.admix.config.PlatformConfig;

public class AdIniter extends ADMixAdapterIniter {

    @Override
    public void initialize(Context context, PlatformConfig config) {
        SdkConfig sdkConfig = new SdkConfig.Builder()
                .appId(config.getAppId())
                .showNotification(true)
                .setInitCallback(new KsInitCallback() {
                    @Override
                    public void onSuccess() {
                        callInitSuccess();
                    }

                    @Override
                    public void onFail(int i, String s) {
                        callInitFailed(i, s);
                    }
                })
                .build();

        KsAdSDK.init(context, sdkConfig);

    }

    @Override
    public String platformName() {
        return "KS";
    }
} 